# -*- coding: UTF-8 -*-
# @author: rain_lane
# @email: 1172965673@qq.com
# @file: _12.py
# @time: 2021/6/12 10:16
# @Software: PyCharm


import requests
import base64


headers = {
    'User-Agent': 'yuanrenxue.project'
}

num = list()
for i in range(1,6):
    m = 'yuanrenxue{}'.format(i)
    m = base64.b64encode(m.encode('utf-8'))
    param_data = {
        'page': i,
        'm': m
    }
    url = 'http://match.yuanrenxue.com/api/match/12'
    res = requests.get(url=url, headers=headers, params=param_data).json()
    for i in res['data']:
        num.append(i['value'])

print(sum(num))
